<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
    <title>Title</title>
    <%@ include file="common.jsp" %>
    <script src="/static/js/saleOut.js"></script>
</head>
<body>
<table id="orderBill_datagrid"></table>
<div id="product_view"><table id="product_datagrid"></table></div>
<div id="orderBill_toolbar">
    <a id="add-dataGrid" class="easyui-linkbutton" iconCls="icon-add" plain="true" data-cmd="add">销售商品</a>
    <a class="easyui-linkbutton" iconCls="icon-reload" plain="true" data-cmd="audit">审核</a>
    <input id="keyword" name="keyword" class="easyui-textbox"/>
    <a class="easyui-linkbutton" iconCls="icon-search" plain="true" data-cmd="query"></a>
</div>
<div id="form_btns">
    <a iconCls="icon-save" class="easyui-linkbutton" plain="true" data-cmd="save">保存</a>
    <a iconCls="icon-cancel" class="easyui-linkbutton" plain="true" data-cmd="cancel">取消</a>
</div>

<table id="itemTr">
    <tr>
        <td></td>
        <td>
            <span tag="sn" name="product.sn"></span>
            <input tag="pId" type="hidden" name="product.id"/>
        </td>
        <td><span tag="productName" name="product.name"></span></td>
        <td><input tag="totalNumber" type="number" name="totalNumber"/></td>
        <td><input tag="salePrice" type="number" name="salePrice"/></td>
        <td><span tag="countPrice" name="countPrice"></span></td>
        <td>
            <a class="easyui-linkbutton del" iconCls="icon-remove" plain="true" data-cmd="remove"></a>
        </td>
    </tr>
</table>

<div id="order_dialog">
    <form id="order_form" method="post">
        <input type="hidden" name="id"/>
        <!--创建表格用于写入操作的数据-->
        <table align="center" style="margin-top: 1px">
            <tbody>
                <tr>
                    <td>
                        <a class="easyui-linkbutton" iconCls="icon-add" plain="true" data-cmd="addProduct"></a>
                    </td>
                    <td><input tag="sn" class="easyui-textbox" name="sn" data-options="required:true" prompt="出库单据"/></td>
                    <td></td>
                    <td><input name="depot.id" class="easyui-combobox"  prompt="仓库"
                        data-options="url:'/depot/list.do',textField:'name',valueField:'id',panelHeight:'auto',required:true"/></td>
                    <td></td>
                    <td><input name="vdate" class="easyui-datebox" data-options="required:true" prompt="销售时间"/></td>
                </tr>
            </tbody>
        </table>
        <table>
            <thead>
            <tr style="text-align: center;">
                <td></td>
                <td width="152">编码</td>
                <td width="137">商品名称</td>
                <td width="143">数量</td>
                <td width="100">单价</td>
                <td width="150">总金额</td>
                <td></td>
            </tr>
            </thead>
            <tbody id="tr_appendTo">
            </tbody>
        </table>
    </form>
</div>

</body>
</html>
